#pragma once
#include<iostream>
#include<list>
#include<deque>
using namespace std;

namespace ganyu
{
	template<class T, class Container = deque<T>>
	class Queue
	{
	public:
		void push(const T& val)
		{
			_con.push_back(val);
		}

		const T& front() const
		{
			auto it = _con.begin();
			return *it;
		}

		T& front()
		{
			typename Container::iterator it = _con.begin();
			return *it;
		}

		const T& back() const
		{
			auto it = _con.rbegin();
			return *it;
		}

		T& back() 
		{
			typename Container::reverse_iterator it = _con.rbegin();
			return *it;
		}

		void pop()
		{
			_con.pop_front();
		}

		bool empty() const
		{
			return _con.empty();
		}

		const size_t size() const
		{
			return _con.size();
		}

	private:
		Container _con;
	};
}
